public class JVMStackSOF {

    private  int stackLenth;
    public void stackLeak(){
        stackLenth++;
        stackLeak();
    }

    public static void main(String[] args) {
        JVMStackSOF sof = new JVMStackSOF();

        try {
            sof.stackLeak();
        }catch (Throwable t){
            System.out.println(t.toString() +"----"+sof.stackLenth);
            throw t;
        }
    }
}
